package cn.stard.controller;

import cn.stard.domian.User;
import cn.stard.feign.UserFeign;
import com.alibaba.csp.sentinel.annotation.SentinelResource;
import com.alibaba.csp.sentinel.slots.block.BlockException;
import lombok.AllArgsConstructor;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

@RestController
@AllArgsConstructor
public class OrderFeign {
    private UserFeign userFeign;
    @GetMapping("/getUserByid/{id}")
    public User getUserByid(@PathVariable Long id){
        return userFeign.getUserByid(id);
    }


}
